package extensionTools.smvCreator;

/**
 * This class represents an instance object in OPM.
 * @author Oshrit & Lital
 *
 */
public class SmvInstanceObject extends SmvObject
{
        private String value;
        private String fatherInstanceName;
        
        public SmvInstanceObject(SmvObject instanceObject, String value, SmvObject fatherObject) 
        {
                super(instanceObject.getId(), instanceObject.getName(), instanceObject.isEnvironmental());
                this.setLinkList(instanceObject.getLinkList());
                this.setStateList(fatherObject.getStateList());
                this.setValue(value);
                this.setFatherInstanceName(fatherObject.getName());         
        }

        public void setValue(String value) {
                this.value = value;
        }

        public String getValue() {
                return value;
        }

        public void setFatherInstanceName(String fatherInstanceName) {
                this.fatherInstanceName = fatherInstanceName.replaceAll(" ", "_").replace("\n", "_");
        }

        public String getFatherInstanceName() {
                return fatherInstanceName;
        }


}
